class LyGoodsModel {
  LyGoodsModel({
    this.goodsId,
    this.code,
    this.icon,
    this.type,
    this.subType,
    this.discount,
    this.originalPrice,
    this.price,
    this.exchangeCoin,
    this.originalExchangeCoin,
    this.originalPriceRupee,
    this.priceRupee,
    this.localPaymentPriceRupee,
    this.isPromotion,
    this.localPayOriginalPrice,
    this.localPayPrice,
  });

  LyGoodsModel.fromJson(dynamic json) {
    goodsId = json['goodsId'];
    code = json['code'];
    icon = json['icon'];
    type = json['type'];
    subType = json['subType'];
    discount = json['discount'];
    originalPrice = json['originalPrice'];
    price = json['price'];
    exchangeCoin = json['exchangeCoin'];
    originalExchangeCoin = json['originalExchangeCoin'];
    originalPriceRupee = json['originalPriceRupee'];
    priceRupee = json['priceRupee'];
    localPaymentPriceRupee = json['localPaymentPriceRupee'];
    isPromotion = json['isPromotion'];
    localPayOriginalPrice = json['localPayOriginalPrice'];
    localPayPrice = json['localPayPrice'];
    tags = json['tags'];
  }
  String? goodsId;
  String? code;
  String? icon;
  String? type;
  num? subType;
  num? discount;
  num? originalPrice;
  num? price;
  num? exchangeCoin;
  num? originalExchangeCoin;
  num? originalPriceRupee;
  num? priceRupee;
  num? localPaymentPriceRupee;
  bool? isPromotion;
  num? localPayOriginalPrice;
  num? localPayPrice;
  String? tags;
  LyGoodsModel copyWith({
    String? goodsId,
    String? code,
    String? icon,
    String? type,
    num? subType,
    num? discount,
    num? originalPrice,
    num? price,
    num? exchangeCoin,
    num? originalExchangeCoin,
    num? originalPriceRupee,
    num? priceRupee,
    num? localPaymentPriceRupee,
    bool? isPromotion,
    num? localPayOriginalPrice,
    num? localPayPrice,
  }) =>
      LyGoodsModel(
        goodsId: goodsId ?? this.goodsId,
        code: code ?? this.code,
        icon: icon ?? this.icon,
        type: type ?? this.type,
        subType: subType ?? this.subType,
        discount: discount ?? this.discount,
        originalPrice: originalPrice ?? this.originalPrice,
        price: price ?? this.price,
        exchangeCoin: exchangeCoin ?? this.exchangeCoin,
        originalExchangeCoin: originalExchangeCoin ?? this.originalExchangeCoin,
        originalPriceRupee: originalPriceRupee ?? this.originalPriceRupee,
        priceRupee: priceRupee ?? this.priceRupee,
        localPaymentPriceRupee:
            localPaymentPriceRupee ?? this.localPaymentPriceRupee,
        isPromotion: isPromotion ?? this.isPromotion,
        localPayOriginalPrice:
            localPayOriginalPrice ?? this.localPayOriginalPrice,
        localPayPrice: localPayPrice ?? this.localPayPrice,
      );
  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['goodsId'] = goodsId;
    map['code'] = code;
    map['icon'] = icon;
    map['type'] = type;
    map['subType'] = subType;
    map['discount'] = discount;
    map['originalPrice'] = originalPrice;
    map['price'] = price;
    map['exchangeCoin'] = exchangeCoin;
    map['originalExchangeCoin'] = originalExchangeCoin;
    map['originalPriceRupee'] = originalPriceRupee;
    map['priceRupee'] = priceRupee;
    map['localPaymentPriceRupee'] = localPaymentPriceRupee;
    map['isPromotion'] = isPromotion;
    map['localPayOriginalPrice'] = localPayOriginalPrice;
    map['localPayPrice'] = localPayPrice;
    map['tags'] = tags;
    return map;
  }
}
